package cn.icanci.loopstack.ras.client.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * @author icanci
 * @since 1.0 Created in 2023/01/06 22:28
 */
@Component
@ConfigurationProperties(prefix = "ras-client")
public class RasClientProperties {
    /**
     * appId
     */
    private String appId;

    /**
     * 客户端注册的port
     */
    private int    clientPort  = 11000;
    /**
     * 服务端ip，以,分隔
     */
    private String serverIps   = "127.0.0.1";
    /**
     * 服务端port
     */
    private int    serverPort  = 9995;
    /**
     * 负载均衡算法
     * 默认算法为调用速度最快的算法
     */
    private String loadBalance = "FASTEST_CALL_SPEED";

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public int getClientPort() {
        return clientPort;
    }

    public void setClientPort(int clientPort) {
        this.clientPort = clientPort;
    }

    public String getServerIps() {
        return serverIps;
    }

    public void setServerIps(String serverIps) {
        this.serverIps = serverIps;
    }

    public int getServerPort() {
        return serverPort;
    }

    public void setServerPort(int serverPort) {
        this.serverPort = serverPort;
    }

    public String getLoadBalance() {
        return loadBalance;
    }

    public void setLoadBalance(String loadBalance) {
        this.loadBalance = loadBalance;
    }
}
